package com.lanju.service;

import java.util.Map;

import com.lanju.entity.User;

public interface JedisService {
	
	
	/**
	 * 获取key的值
	 * @param key
	 * @return
	 */
	public Map<String,Object> get(String key);
	/**
	 * 设置map
	 * @param key
	 * @param map
	 * @param seconds  过期时间，单位秒
	 * @return
	 */
	public Map<String,Object> setMap(String key,Map<String,String> map,int seconds);
	/**
	 * 获取map的值
	 * @param key
	 * @param field
	 * @return
	 */
	public Map<String,Object> getMap(String key,String... field);
	/**
	 * 查询key和域是否存在
	 * @param key
	 * @param field
	 * @return
	 */
	public Boolean hexists(String key,String field);
	
	public User getUser(String key,String... field);
	
	public Long delKey(String key);
	
	public String setValue(String key,String val,int seconds);
	
	public String getVal(String key);
}
